﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Admin/AdminMasterPage.master" AutoEventWireup="true"
    CodeBehind="ManageUser.aspx.cs" Inherits="TuyenDungViecLam.Admin.ManageUser" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder4" runat="server">
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>
            <div class="art-Block">
                <div class="art-Block-tl">
                </div>
                <div class="art-Block-tr">
                </div>
                <div class="art-Block-bl">
                </div>
                <div class="art-Block-br">
                </div>
                <div class="art-Block-tc">
                </div>
                <div class="art-Block-bc">
                </div>
                <div class="art-Block-cl">
                </div>
                <div class="art-Block-cr">
                </div>
                <div class="art-Block-cc">
                </div>
                <div class="art-Block-body">
                    <div class="art-BlockHeader">
                        <div class="art-header-tag-icon">
                            <div class="t">
                                Quản Lý User</div>
                        </div>
                    </div>
                    <div class="art-BlockContent">
                        <div id="divCapnhat" runat="server">
                            <div>
                                <center>
                                    <asp:Label ID="Label1" runat="server" Text="Label"> Tìm Kiếm User:</asp:Label>
                                    <asp:TextBox ID="txtUsername" Width="200px" runat="server"></asp:TextBox>
                                    <asp:Button ID="BtSearch" runat="server" Text="Tìm Kiếm" CssClass="button" 
                                        Style="display: inline" onclick="BtSearch_Click" />
                                </center>
                            </div>
                            <br />
                            <div>
                                <center>
                                    <asp:GridView ID="GrvManageUser" runat="server" AutoGenerateColumns="False" GridLines="None"
                                        CellPadding="4" ForeColor="#333333" OnRowCommand="GrvManageUser_RowCommand" OnRowDataBound="GrvManageUser_RowDataBound"
                                        AllowPaging="True" OnPageIndexChanging="GrvManageUser_PageIndexChanging" OnRowDeleting="GrvManageUser_RowDeleting">
                                        <RowStyle BackColor="#EFF3FB" />
                                        <Columns>
                                            <asp:TemplateField HeaderText="Active">
                                                <ItemTemplate>
                                                    <asp:CheckBox ID="cbchon" runat="server" />
                                                    <asp:Label ID="Status" runat="server" Text='<%# Eval("STATUS")%>' Visible="false"></asp:Label>
                                                    <asp:Label ID="lbuser" runat="server" Text='<%# Eval("USERNAME")%>' Visible="false"></asp:Label>
                                                </ItemTemplate>
                                                <HeaderStyle Width="100px" />
                                                <ItemStyle HorizontalAlign="Center" />
                                            </asp:TemplateField>
                                            <asp:BoundField HeaderText="Username" DataField="UserName">
                                                <HeaderStyle Width="200px" />
                                                <ItemStyle HorizontalAlign="Center" />
                                            </asp:BoundField>
                                            <asp:TemplateField>
                                                <ItemTemplate>
                                                    <%--<asp:LinkButton ID="Edit" CommandName="Edit" CommandArgument='<%# Eval("USER_ID") %>'
                                                        runat="server">Edit User</asp:LinkButton>--%>
                                                    <asp:ImageButton ID="Edit" CommandName="Edit" CommandArgument='<%# Eval("USER_ID") %>'
                                                        ImageUrl="~/images/edit-user-icon.png" runat="server" />
                                                </ItemTemplate>
                                                <HeaderStyle Width="100px" />
                                                <ItemStyle HorizontalAlign="Center" />
                                            </asp:TemplateField>
                                            <asp:TemplateField>
                                                <ItemTemplate>
                                                    <asp:ImageButton ID="EditRole" CommandName="EditRole" CommandArgument='<%# Eval("USER_ID") %>'
                                                        ImageUrl="~/images/modify-key-icon.png" runat="server" />
                                                </ItemTemplate>
                                                <HeaderStyle Width="100px" />
                                                <ItemStyle HorizontalAlign="Center" />
                                            </asp:TemplateField>
                                            <asp:TemplateField>
                                                <ItemTemplate>
                                                    <asp:ImageButton ID="Delete" CommandName="Delete" ImageUrl="~/images/delete-icon.png"
                                                        CommandArgument='<%# Eval("USER_ID") %>' runat="server" />
                                                </ItemTemplate>
                                                <HeaderStyle Width="100px" />
                                                <ItemStyle HorizontalAlign="Center" />
                                            </asp:TemplateField>
                                        </Columns>
                                        <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                                        <PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" CssClass="PagingGrid" />
                                        <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
                                        <HeaderStyle CssClass="HeaderGrid" />
                                        <EditRowStyle BackColor="#2461BF" />
                                        <AlternatingRowStyle BackColor="White" />
                                    </asp:GridView>
                                </center>
                            </div>
                        </div>
                        <div id="divThongbao" runat="server" visible="false" style="text-align: center">
                            <asp:Label ID="lbThongbao" runat="server" Text="" Font-Size="24"> </asp:Label>
                            <br />
                            <asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl="~/Admin/ManageUser.aspx">Back</asp:HyperLink>
                        </div>
                    </div>
                </div>
            </div>
        </ContentTemplate>
    </asp:UpdatePanel>
</asp:Content>
